var loadsoftDetInfo = function(id) {
	console.log(id)
	mui.ajax('../loanJournal/findByLoanId4Mobile.action', {
		data: {
			'loanId' : id 
		},
		dataType:'json',//服务器返回json格式数据
		type:'post',//HTTP请求类型
		timeout:10000,//超时时间设置为10秒；			
		success: function (data) {
            if (data.success == 'true') {
            	document.getElementById('historyRout').innerHTML = data.data;
            } else {
            	mui.alert(data.data);
            }
        }
	})
};

var getUrlParam=function(name) {
	 var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)"); //构造一个含有目标参数的正则表达式对象
	 var urlParam = window.location.search.substr(1);
	 var r = decodeURI(urlParam).match(reg);  //匹配目标参数
	 if (r != null) return unescape(r[2]); return null; //返回参数值

};

(function($, owner) {
	
	var loanId = getUrlParam('loanId');
	loadsoftDetInfo(loanId);

	mui('.mui-scroll-wrapper').scroll({deceleration: 0.0005});
}(mui, window.app = {}));
